<?php
$plugin->load_plugin_lang();

$post_var_receive = retrieve(POST,'title', '');
$post_var_receive2 = retrieve(POST,'text', '');
if($post_var_receive!='')
{
	$Sql->query_inject("INSERT INTO phpboost_plugin_display_text (title, text) VALUES ('".$post_var_receive."', '".$post_var_receive2."')",__LINE__,__FILE__);
	$last_id = $Sql->insert_id("SELECT MAX(id) FROM phpboost_plugin_display_text");
	
	$plugin->save_module($last_id);
}

$tpl = new Template_plugin('course/plugin/display_text/templates/admin/index.tpl');

$tpl->assign_vars(array(
	'TEST_VAR_LANG'=>$LANG['test'],
	'ACTION_FORM'=>$currentLink."index",
	'CONFIRM'=>$LANG['confirm_message'],
));

$tpl->parse();
?>